﻿<?xml version="1.0" encoding="utf-8"?>
<xs:schema id="DataBaseHotelDataSet" targetNamespace="http://tempuri.org/DataBaseHotelDataSet.xsd" xmlns:mstns="http://tempuri.org/DataBaseHotelDataSet.xsd" xmlns="http://tempuri.org/DataBaseHotelDataSet.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:msprop="urn:schemas-microsoft-com:xml-msprop" attributeFormDefault="qualified" elementFormDefault="qualified">
  <xs:annotation>
    <xs:appinfo source="urn:schemas-microsoft-com:xml-msdatasource">
      <DataSource DefaultConnectionIndex="0" FunctionsComponentName="QueriesTableAdapter" Modifier="AutoLayout, AnsiClass, Class, Public" SchemaSerializationMode="IncludeSchema" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
        <Connections>
          <Connection AppSettingsObjectName="Settings" AppSettingsPropertyName="DataBaseHotelConnectionString" ConnectionStringObject="" IsAppSettingsProperty="true" Modifier="Assembly" Name="DataBaseHotelConnectionString (Settings)" ParameterPrefix="@" PropertyReference="ApplicationSettings.University.Workshop.WinApp.Properties.Settings.GlobalReference.Default.DataBaseHotelConnectionString" Provider="System.Data.SqlClient" />
        </Connections>
        <Tables>
          <TableAdapter BaseClass="System.ComponentModel.Component" DataAccessorModifier="AutoLayout, AnsiClass, Class, Public" DataAccessorName="roomTableAdapter" GeneratorDataComponentClassName="roomTableAdapter" Name="room" UserDataComponentName="roomTableAdapter">
            <MainSource>
              <DbSource ConnectionRef="DataBaseHotelConnectionString (Settings)" DbObjectName="DataBaseHotel.dbo.room" DbObjectType="Table" FillMethodModifier="Public" FillMethodName="Fill" GenerateMethods="Both" GenerateShortCommands="true" GeneratorGetMethodName="GetData" GeneratorSourceName="Fill" GetMethodModifier="Public" GetMethodName="GetData" QueryType="Rowset" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetData" UserSourceName="Fill">
                <DeleteCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="false">
                    <CommandText>DELETE FROM [dbo].[room] WHERE (([idRoom] = @Original_idRoom) AND ([idType] = @Original_idType))</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@Original_idRoom" Precision="0" ProviderType="Int" Scale="0" Size="0" SourceColumn="idRoom" SourceColumnNullMapping="false" SourceVersion="Original" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@Original_idType" Precision="0" ProviderType="Int" Scale="0" Size="0" SourceColumn="idType" SourceColumnNullMapping="false" SourceVersion="Original" />
                    </Parameters>
                  </DbCommand>
                </DeleteCommand>
                <InsertCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="false">
                    <CommandText>INSERT INTO [dbo].[room] ([Name], [idType]) VALUES (@Name, @idType);
SELECT idRoom, Name, idType FROM room WHERE (idRoom = SCOPE_IDENTITY())</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="String" Direction="Input" ParameterName="@Name" Precision="0" ProviderType="NVarChar" Scale="0" Size="0" SourceColumn="Name" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@idType" Precision="0" ProviderType="Int" Scale="0" Size="0" SourceColumn="idType" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </InsertCommand>
                <SelectCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="false">
                    <CommandText>SELECT idRoom, Name, idType FROM dbo.room</CommandText>
                    <Parameters />
                  </DbCommand>
                </SelectCommand>
                <UpdateCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="false">
                    <CommandText>UPDATE [dbo].[room] SET [Name] = @Name, [idType] = @idType WHERE (([idRoom] = @Original_idRoom) AND ([idType] = @Original_idType));
SELECT idRoom, Name, idType FROM room WHERE (idRoom = @idRoom)</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="String" Direction="Input" ParameterName="@Name" Precision="0" ProviderType="NVarChar" Scale="0" Size="0" SourceColumn="Name" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@idType" Precision="0" ProviderType="Int" Scale="0" Size="0" SourceColumn="idType" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@Original_idRoom" Precision="0" ProviderType="Int" Scale="0" Size="0" SourceColumn="idRoom" SourceColumnNullMapping="false" SourceVersion="Original" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@Original_idType" Precision="0" ProviderType="Int" Scale="0" Size="0" SourceColumn="idType" SourceColumnNullMapping="false" SourceVersion="Original" />
                      <Parameter AllowDbNull="false" AutogeneratedName="idRoom" ColumnName="idRoom" DataSourceName="DataBaseHotel.dbo.room" DataTypeServer="int" DbType="Int32" Direction="Input" ParameterName="@idRoom" Precision="0" ProviderType="Int" Scale="0" Size="4" SourceColumn="idRoom" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </UpdateCommand>
              </DbSource>
            </MainSource>
            <Mappings>
              <Mapping SourceColumn="idRoom" DataSetColumn="idRoom" />
              <Mapping SourceColumn="Name" DataSetColumn="Name" />
              <Mapping SourceColumn="idType" DataSetColumn="idType" />
            </Mappings>
            <Sources />
          </TableAdapter>
        </Tables>
        <Sources />
      </DataSource>
    </xs:appinfo>
  </xs:annotation>
  <xs:element name="DataBaseHotelDataSet" msdata:IsDataSet="true" msdata:UseCurrentLocale="true" msprop:EnableTableAdapterManager="True" msprop:Generator_DataSetName="DataBaseHotelDataSet" msprop:Generator_UserDSName="DataBaseHotelDataSet">
    <xs:complexType>
      <xs:choice minOccurs="0" maxOccurs="unbounded">
        <xs:element name="room" msprop:Generator_TableClassName="roomDataTable" msprop:Generator_TableVarName="tableroom" msprop:Generator_TablePropName="room" msprop:Generator_RowDeletingName="roomRowDeleting" msprop:Generator_UserTableName="room" msprop:Generator_RowChangingName="roomRowChanging" msprop:Generator_RowEvHandlerName="roomRowChangeEventHandler" msprop:Generator_RowDeletedName="roomRowDeleted" msprop:Generator_RowEvArgName="roomRowChangeEvent" msprop:Generator_RowChangedName="roomRowChanged" msprop:Generator_RowClassName="roomRow">
          <xs:complexType>
            <xs:sequence>
              <xs:element name="idRoom" msdata:ReadOnly="true" msdata:AutoIncrement="true" msdata:AutoIncrementSeed="-1" msdata:AutoIncrementStep="-1" msprop:Generator_ColumnVarNameInTable="columnidRoom" msprop:Generator_ColumnPropNameInRow="idRoom" msprop:Generator_ColumnPropNameInTable="idRoomColumn" msprop:Generator_UserColumnName="idRoom" type="xs:int" />
              <xs:element name="Name" msprop:Generator_ColumnVarNameInTable="columnName" msprop:Generator_ColumnPropNameInRow="Name" msprop:Generator_ColumnPropNameInTable="NameColumn" msprop:Generator_UserColumnName="Name">
                <xs:simpleType>
                  <xs:restriction base="xs:string">
                    <xs:maxLength value="2147483647" />
                  </xs:restriction>
                </xs:simpleType>
              </xs:element>
              <xs:element name="idType" msprop:Generator_ColumnVarNameInTable="columnidType" msprop:Generator_ColumnPropNameInRow="idType" msprop:Generator_ColumnPropNameInTable="idTypeColumn" msprop:Generator_UserColumnName="idType" type="xs:int" />
            </xs:sequence>
          </xs:complexType>
        </xs:element>
      </xs:choice>
    </xs:complexType>
    <xs:unique name="Constraint1" msdata:PrimaryKey="true">
      <xs:selector xpath=".//mstns:room" />
      <xs:field xpath="mstns:idRoom" />
    </xs:unique>
  </xs:element>
</xs:schema>